﻿package exercise11;

import java.util.HashMap;

public class Test {

	public static void main(String[] args) {
		Student student=new Student("李明", "男");
        HashMap<String,Student> s=new HashMap<String,Student>();
        s.put("jack",student);
        System.out.println("键集:"+s.keySet());
        System.out.println("值集:"+s.values());
        System.out.println("键-值对集合"+s);
        String key = "jack";  
        if(s.containsKey(key)){  
            System.out.println("学员姓名:"+s.get(key).name);  
        }  
	}

}
